package com.ruoyi.web.controller.sys_ksh;

import com.ruoyi.system.domain.ZhsnOdsIndex;
import com.ruoyi.system.service.IZhsnOdsIndexService;
import org.apache.shiro.authz.annotation.RequiresPermissions;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

import java.util.List;

@Controller
@RequestMapping("/system/main/mainpage")
public class indexController {
    private String prefix = "system/main/mainpage";

    @Autowired
    private IZhsnOdsIndexService zhsnOdsIndexService;

    @RequiresPermissions("system:mainpage:view")
    @GetMapping()
    public String config() {
        return prefix;
    }

    @RequiresPermissions("system:main:mainpage:list1")
    @GetMapping("/list1")
    @ResponseBody
    public List<ZhsnOdsIndex> list1() {
//        System.out.println(zhsnOdsIndexService.select综合评价());
        return zhsnOdsIndexService.select综合评价();
    }
}
